/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

package org.openbookformat.tags;

/**
 *
 * @author MUFEED
 */
public class TagUtil {

    public static String CompositeTagToText(CompositeTag cTag) {
        String rVal = "";
        for(int i = 0; i < cTag.size(); i++)
            rVal += cTag.getTag(i).toString();
        return rVal;
    }
    
    public static CompositeTag textTagToCompositeTag(String text) {
        CompositeTag tag = new CompositeTag();
        tag.addTag(new Text(text));
        return tag;
    }

}
